package cn.kgc.service.impl;
import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import cn.kgc.entity.Goods;
import cn.kgc.mapper.GoodsMapper;
import cn.kgc.service.GoodsService;

@Service
public class GoodsServiceImpl implements GoodsService {
	
	@Resource
	private GoodsMapper goodsMapper;
	
	@Override
	public List<Goods> getAllGoods() {
		return goodsMapper.getAllGoods();
	}

	@Override
	public void addGoods(Goods goods) {
		goodsMapper.addGoods(goods);
		
	}

	@Override
	public Goods getGoodsById(Integer id) {
		return goodsMapper.getGoodsById(id);
	}

	@Override
	public void updateGoods(Goods goods) {
		goodsMapper.updateGoods(goods);
	}

	@Override
	public void deleteGoodsById(Integer id) {
		goodsMapper.deleteGoodsById(id);
	}


	
	
	
	
	
}
